package org.omg.RTCORBA;


/**
 *	Generated from IDL definition of struct "PriorityBand"
 *	@author orbas IDL compiler 
 */

public final class PriorityBandHelper
{
	private static org.omg.CORBA.TypeCode _type = null;
	public static org.omg.CORBA.TypeCode type ()
	{
		if( _type == null )
		{
			_type = org.omg.CORBA.ORB.init().create_struct_tc( org.omg.RTCORBA.PriorityBandHelper.id(),"PriorityBand",new org.omg.CORBA.StructMember[]{new org.omg.CORBA.StructMember("low", org.omg.RTCORBA.PriorityHelper.type(), null),new org.omg.CORBA.StructMember("high", org.omg.RTCORBA.PriorityHelper.type(), null)});
		}
		return _type;
	}

	public static void insert (final org.omg.CORBA.Any any, final org.omg.RTCORBA.PriorityBand s)
	{
		org.omg.CORBA.portable.OutputStream out = any.create_output_stream ();
		any.type (type ());
		write (out, s);
		any.read_value (out.create_input_stream (), type ());
	}

	public static org.omg.RTCORBA.PriorityBand extract (final org.omg.CORBA.Any any)
	{
		return read(any.create_input_stream());
	}

	public static String id()
	{
		return "IDL:org/omg/RTCORBA/PriorityBand:1.0";
	}
	public static org.omg.RTCORBA.PriorityBand read (final org.omg.CORBA.portable.InputStream in)
	{
		org.omg.RTCORBA.PriorityBand result = new org.omg.RTCORBA.PriorityBand();
		result.low=in.read_short();
		result.high=in.read_short();
		return result;
	}
	public static void write (final org.omg.CORBA.portable.OutputStream out, final org.omg.RTCORBA.PriorityBand s)
	{
		out.write_short(s.low);
		out.write_short(s.high);
	}
}
